import re

# str = "12 89 ab cc 11_"
#
# print(re.findall("1\S*", str))
# print(re.findall("12|a", str))

s = """<body>
<h1>标题问题内容</h1>
<h3 class="abc">我字体大小16px,去掉加粗</h3>
</body>"""

result = re.search(r"<h1>(?P<title1>.*)</h1>[\s\S]*<h3.*>(?P<title2>.*)</h3>", s)

print(result.group("title1"))
print(result.group("title2"))